#ifndef IEXPLOSIONMANAGER
#define IEXPLOSIONMANAGER

#include "WorldEntity.h"
#include "Vector2i.h"

//!Represent the type of explosion
/*!
Each type of explosion represent the index of the explosion template.
*/
enum eExplosionType
{
	ePlayerExplosion=0,
	eEnemyExplosion,
	eProjectileExplosion,
	eNumberOfExplosion
};

//!Interface of explosion.
/*!
This class is a virtual class to handle the creation of explosion during the game and the creation of 
template of explosion.
*/
class IExplosionManager
{
	
public:

	//!Destructor.
	virtual ~IExplosionManager(){};

	//!Initialise the Explosion manager.
	virtual void init(void)=0;

	//!Create an example of explosion
	/*!
	\param type The type of explosion.
	\param indexAnimExplosion The index of the animation of the explosion.
	\param sound The index of the sound of the explosion.
	*/
	virtual void createExplosionType(eExplosionType type, int indexAnimExplosion, int sound)=0;

	//!Create blank explosions in the World Model.
	/*!
	\param numberOfEntities The number of explosion to create.
	\return True if numberOfEntities explosions have been created. False if it failed.
	*/
	virtual bool createExplosions(int numberOfEntities)=0;

	//!Activate an explosion.
	/*!
	Activate the first blank explosion of the WorldModel.
	\param type Set the type of the explosion.
	\param position Set the position of the explosion.
	\return True if the explosion was activated. False if there is no blank explosion to activate.
	*/
	virtual bool activeExplosion(eExplosionType type, const CVector2i& position)=0;
};

#endif





